import Vue from 'vue'
import VueRouter from 'vue-router'
Vue.use(VueRouter)

import Home from '@/views/Home'
import Search from '@/views/Search'
import Order from '@/views/Order'
import Personal from '@/views/Personal'
import Login from '@/views/Login'
import ShopInfo from '@/views/ShopInfo'

// 路由配置規則
const routes = [
    {
        path: '/',
        redirect: '/home'
    },
    {
        path: '/home',
        component: Home,
        meta: {
            showFooterGuide: true
        }
    },
    {
        path: '/search',
        component: Search,
        meta: {
            showFooterGuide: true
        }
    },
    {
        path: '/order',
        component: Order,
        meta: {
            showFooterGuide: true
        }
    },
    {
        path: '/personal',
        component: Personal,
        meta: {
            showFooterGuide: true
        }
    },
    {
        path: '/login',
        component: Login
    },
    {
        path: '/shop-info',
        component: ShopInfo
    },

]

const router = new VueRouter({
    routes
})

export default router